package cn.audit.service.approval;

import cn.audit.bean.dto.zuzhangzhengshuai;
import cn.audit.bean.pojo.Approval;
import cn.audit.repository.approval.ApprovalRepository;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import javax.annotation.Resource;
import java.util.List;

/**
 * @Author: 李忆枫
 * @Date: 2019/5/28 21:24
 */
@Service
public class ApprovalService {

    @Resource
    private ApprovalRepository approvalRepository;

    @Transactional(rollbackFor = Exception.class)
    public void save(Approval approval) {
        approvalRepository.save(approval);
    }

    public List<zuzhangzhengshuai> eee() {
        return approvalRepository.eee();
    }

}
